#ifndef __FIGUR__
#define __FIGUR__

#include "Graphics.h"
#include "env_element.h"

#define ACCELLERATE 0.7
#define XACCEL 1
#define XMAX 6
#define ANIMDELAY 2

enum ANIMS{WALK, JUMP};

class Figur
{
protected:
	int x, y;
	int framex;
	int framey;
	int anim_max;
	int anim_count;
	bool touchdown;
	int moving;
	int direct;
	double xspeed, yspeed;
	int * scrollx,*scrolly;

	ALLEGRO_BITMAP * cur_Animation;

	Graphics ** GR;
	env_element ** cur_env;

	Box Hitbox;
	//Box Hitboxes[3];		// evt sinnvoll um nicht auf pixelkollision umzusteigen

public:
	Figur();
	Figur(Graphics ** gr,env_element ** cur_env_element,int * scrollx, int * scrolly);
	void draw(ALLEGRO_DISPLAY ** display);
	void set_touchdown(bool val);
	void move_r();
	void move_l();
	void jump();
	void stop();
	int get_direction();
	int get_moving();
	bool get_touchdown();
	void set_env(env_element ** cur);
	void change_Animation(int anim);
	int get_x();
	int get_y();
	~Figur();

};


#endif